<%@page import="org.springframework.web.context.request.SessionScope"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@	page import="kau.dao.*"%>
<%@	page import="kau.vo.*"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<title>기본정보수정</title>

<script type="text/javascript">
	function mainSubmit() {
		var pwd = fm.pwd.value; //입력한 패스어ㄷ워드
		var pw = fm.pw.value; // 기존 패스워드

		if (pwd == '') {
			alert('비밀번호를 입력하세요.');
			document.getElementById("pwd").focus();
			return false;
		} else if (pwd == pw) {
			alert('회원수정페이지로 이동합니다.');
			return true;
		} else {
			alert('비밀번호를 확인하세요.');
			document.getElementById("pwd").focus();
			return false;
		}
	}
</script>

<style type="text/css">
#info {
	font-family: 맑은 고딕, dotum, sans-serif, bold;
	font-size: 13px
}
</style>

<style type="text/css">
<!--
@import url("/nems/css/style.css");
-->
</style>
</head>
<body>


	<%
		String custId = (String) session.getAttribute("custId");
		String pw = CustomerDAOImpl.getInstance().getCustomer(custId)
				.getPassword();
	%>


	<div id="info" style="margin-left: 20px; margin-bottom: 30px">
		<div class="content_header">
			<br>
			<table align="left">
				<tr>

					<td><img src="/nems/cust/img/myPageImg.png" width="40"
						alt="기본정보 수정" /></td>

					<td>
						<h4
							style="font-weight: bold; color: #005700; text-align: left; font-size: 20px;">기본정보수정</h4>
					</td>
				</tr>
			</table>
			<center>
				<br> <br> <br>
				<p>회원님의 회원정보를 수정할 수 있습니다.</p>
				<br>

				<p>
					<strong>개인정보 보호를 위해 비밀번호를 입력해주세요.</strong>
				</p>
			</center>
		</div>
		<div class="section">

			<form id="fm" name="fm" method="post"
				action="index.jsp?contentMenu=/cust/myPage.jsp&content=/cust/updateInfo2.jsp">


				<div class="id_pw">

					<input type="hidden" name="custId" value="<%=custId%>" /> <input
						type="hidden" name="pw" value="<%=pw%>">


					<table width="600" border="0">
						<tr>
							<td colspan="2">
								<hr width="670">
							</td>
						</tr>
						<tr align="center">
							<td width="300" height="40">아이디</td>
							<td width="300">${sessionScope.custId}</td>
						</tr>
						<tr align="center">
							<td width="300" height="40">비밀번호</td>
							<td><input type="password" id="pwd" name="pwd" /></td>
						</tr>
						<tr>
							<td colspan="2">
								<hr width="670">
							</td>
						</tr>

						<tr align="center">
							<td colspan="2"><br> <br> <img
								src="/nems/cust/img/myPageSubmsg.png"><br> <br></td>
						</tr>

						<tr align="center">
							<td colspan="2">
								<button class="positive" style="width: 70px" type="submit"
									onclick="return mainSubmit()">
									<img src="cust/img/shopping_cart_accept.png"
										style="width: 20px; height: 10px" />확인
								</button>
							</td>
						</tr>


					</table>
			</form>
		</div>

	</div>
</body>
</html>